Skip to content

Support map values in (when)#191

Merged
alexander-yevsyukov merged 10 commits intomasterfrom
support-map-values-in-when
May 1, 2026
Merged

Support map values in (when)#191
alexander-yevsyukov merged 10 commits intomasterfrom
support-map-values-in-when

Conversation

@alexander-yevsyukov
Copy link
Copy Markdown
Contributor

@alexander-yevsyukov alexander-yevsyukov commented Apr 30, 2026

This PR extends the validation module with the support of map values constrained with the (when) option.

Other notable changes

  • Test suites under the test were split by types of the checked fields.
  • Latest config was applied.

@alexander-yevsyukov alexander-yevsyukov changed the title Support map values in when Support map values in (when) Apr 30, 2026
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 30, 2026

Codecov Report

❌ Patch coverage is 0% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 83.88%. Comparing base (ff52ea3) to head (353da29).
⚠️ Report is 11 commits behind head on master.

Additional details and impacted files
@@             Coverage Diff              @@
##             master     #191      +/-   ##
============================================
- Coverage     84.27%   83.88%   -0.39%     
  Complexity      304      304              
============================================
  Files            60       60              
  Lines          1081     1086       +5     
  Branches         45       46       +1     
============================================
  Hits            911      911              
- Misses          160      165       +5     
  Partials         10       10              
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@alexander-yevsyukov alexander-yevsyukov self-assigned this Apr 30, 2026
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR extends the time (when) validation option to support map fields whose values are google.protobuf.Timestamp or Spine Temporal types, and reorganizes the test suite accordingly while bumping project/config versions.

Changes:

  • Add (when) codegen/support for map-valued fields in the validation module.
  • Add new proto fixtures and split tests by field “shape” (single/repeated/map) and by time type (Timestamp/Temporal), with shared time fixtures.
  • Apply latest config updates and bump snapshot versions / dependency reports.

Reviewed changes

Copilot reviewed 32 out of 33 changed files in this pull request and generated 2 comments.

Show a summary per file
File Description
version.gradle.kts Bumps versionToPublish to 2.0.0-SNAPSHOT.237.
validation/.../WhenOption.kt Allows (when) to consider map field types during type classification.
validation/.../WhenGenerator.kt Generates validation code that iterates over map values and validates each element.
tests/.../when_map.proto Adds proto fixtures for (when) on map values (Timestamp + Temporal).
tests/.../TimestampWhenSpec.kt New tests for single Timestamp fields with (when).
tests/.../TimestampWhenMapSpec.kt New tests for map-of-Timestamp fields with (when).
tests/.../TimestampRepeatedWhenSpec.kt Refactors repeated Timestamp tests to use shared fixtures and new suite naming.
tests/.../TemporalWhenSpec.kt New tests for single Temporal fields with (when).
tests/.../TemporalWhenMapSpec.kt New tests for map-of-Temporal fields with (when).
tests/.../TemporalRepeatedWhenSpec.kt New tests for repeated Temporal fields with (when).
tests/.../SpineTemporalWhenSpec.kt Removes old combined Temporal test suite (replaced by split specs).
tests/.../Fixtures.kt Introduces shared TimestampFixtures / TemporalFixtures.
pom.xml Regenerated POM content updated; introduces new dependencies/versions (see comments).
dependencies.md Regenerated license/dependency report with new version headers/timestamps.
buildSrc/.../Validation.kt Bumps Validation dependency version to 2.0.0-SNAPSHOT.414.
buildSrc/.../Time.kt Bumps Time dependency version to 2.0.0-SNAPSHOT.236.
buildSrc/.../CoreJvmCompiler.kt Bumps compiler dogfooding version to 2.0.0-SNAPSHOT.063.
buildSrc/.../Dokka.kt Removes an unused import.
buildSrc/build.gradle.kts Updates Shadow plugin version/comment block.
.junie/guidelines.md Updates Junie guidelines wording.
.gitignore Ignores .junie/memory/.
.github/workflows/*.yml(yaml) Renames some workflow/job display names.
.agents/skills/java-to-kotlin/* Adds “java-to-kotlin” skill metadata.
.agents/quick-reference-card.md Removes a tools recommendation line.
.agents/_TOC.md Points TOC entry to the new skill doc location.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread pom.xml
Comment thread pom.xml
@alexander-yevsyukov alexander-yevsyukov merged commit 49d4156 into master May 1, 2026
7 checks passed
@alexander-yevsyukov alexander-yevsyukov deleted the support-map-values-in-when branch May 1, 2026 17:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants